<template>
	<!-- 门店人员 -->
	<view class="member-container">
		<view class="uni-title mt">
			<text class="title-text">门店人员</text>
			<button type="primary" plain="true" class="member-add-btn" v-if="showAdd">添加人员</button>
		</view>
		<uni-list :border="false"><uni-list-item v-for="member in memberList" :key="member.id" :title="member.name" :thumb="member.avatar" :rightText="member.post" /></uni-list>
	</view>
</template>

<script>
export default {
	name: 'StoreMember',
	props: {
		memberList: {
			type: Array,
			default: () => {
				return [];
			}
		},
		showAdd: {
			type: Boolean,
			default: false
		}
	},
	data() {
		return {};
	},
	methods: {}
};
</script>

<style scoped lang="scss">
.member-container {
	.uni-title {
		display: flex;
		
		.title-text {
			flex: 1;
			display: inline-block;
		}
	}
	.member-add-btn {
		font-size: 24upx;
	}
}
</style>
